package com.msb.mall.order;

import com.msb.mall.common.utils.R;
import com.msb.mall.order.feign.ProductFeignService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/order")
public class TestController {
    @Autowired
    private ProductFeignService productFeignService;
    @Value("${test.name:}")
    private String name;

    @GetMapping("/test01")
    public R test01() {
        return productFeignService.test();
    }

    @GetMapping("/test02")
    public String test02() {
        return this.name;
    }
}
